package com.ego.product.po;

import cn.hutool.core.bean.BeanUtil;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;

import java.io.Serializable;

import com.ego.product.vo.AttrGroupWithAttrVo;
import lombok.Data;

/**
 * @program: ego
 * @description 属性分组
 * @author KamTang
 * @date 2022-11-13 12:56:14
 */
@Data
@TableName("pms_attr_group")
public class AttrGroup implements Serializable {
	private static final long serialVersionUID = 1L;

	/**
	 * 分组id
	 */
	@TableId
	private Long attrGroupId;
	/**
	 * 组名
	 */
	private String attrGroupName;
	/**
	 * 排序
	 */
	private Integer sort;
	/**
	 * 描述
	 */
	private String description;
	/**
	 * 组图标
	 */
	private String icon;
	/**
	 * 所属分类id
	 */
	private Long categoryId;
	/**
	 * 路径
	 */
	@TableField(exist = false)
	private Long[] categoryPath;

	public AttrGroupWithAttrVo toVo() {
		return BeanUtil.copyProperties(this, AttrGroupWithAttrVo.class);
	}
}
